# Maintainer: Antoni Aloy <aaloytorrens@gmail.com>
pkgname=pdfarranger
pkgver=1.10.1
pkgrel=1
pkgdesc="Helps merge or split PDF documents and rotate, crop and rearrange pages"
url="https://github.com/pdfarranger/pdfarranger"
arch="noarch"
license="GPL-3.0-or-later"
depends="
	desktop-file-utils
	ghostscript
	gsettings-desktop-schemas
	gtk+3.0
	poppler-glib
	py3-atspi
	py3-cairo
	py3-dateutil
	py3-gobject3
	py3-img2pdf
	py3-pikepdf
	"
makedepends="
	intltool
	py3-gpep517
	py3-setuptools
	py3-wheel
	"
options="!check" # tests require dogtail package
subpackages="$pkgname-lang $pkgname-doc $pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/pdfarranger/pdfarranger/archive/$pkgver.tar.gz"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
a0bebb569570656217e4f9432c0a3fbdb7f441b7ee04dc82f31e449befec19a1fa1045ef7ce95dc75e9feb14fad9a0265307efdf221c8a727091c05348554427  pdfarranger-1.10.1.tar.gz
"
